Skip to content

chore(release): v1.0.3 — Actions dropdown polish + sidebar identity refactor (#574 #575 #578)#579

Merged
MartinCastroAlvarez merged 1 commit into
mainfrom
chore/release-v1.0.3
May 28, 2026
Merged

chore(release): v1.0.3 — Actions dropdown polish + sidebar identity refactor (#574 #575 #578)#579
MartinCastroAlvarez merged 1 commit into
mainfrom
chore/release-v1.0.3

Conversation

@MartinCastroAlvarez
Copy link
Copy Markdown
Owner

v1.0.3 — Actions dropdown polish + sidebar identity refactor

Three issues converged on the shared Popover primitive in @dar/ui — addressed together.

#574 — Actions dropdown width tracks label length

The list-page Actions dropdown opened at a fixed narrow width (~200px). Long @admin.action(description="...") labels wrapped to 2-3 lines each, making 5-item menus a tall block.

Fix: panelClassName="min-w-56 max-w-md py-1" — width tracks the longest label between 14rem and 28rem. Items are truncate whitespace-nowrap; longer-than-max labels get with the full text reachable via the existing title= tooltip.

#575 — Actions dropdown closes on outside click

The hand-rolled menu had no outside-click handler; only the trigger button or an item click dismissed it. Acted like a modal without being one.

Fix: replace the hand-rolled <div className="relative"> + open-state-toggle with the shared <Popover> primitive, which already inherits outside-click + Escape close from the same component the filter dropdowns and CustomViewsMenu use. Zero new code — pure refactor onto the right primitive.

#578 — Sidebar identity dropdown over modal

Three things in the sidebar identity area were doing one job:

  • <email> · superuser text on its own row (the role label was noise for day-to-day users)
  • A standalone Settings button
  • A <SettingsModal> containing theme toggle + Sign out

A modal around two controls is heavy primitive choice; the theme + logout pair is the canonical "profile dropdown" shape.

Fix:

  • New <AccountMenu> component in @dar/settings is the panel body (theme + Sign out + optional Signed in as <email> · <role> caption).
  • Sidebar mounts it inside a <Popover> anchored to an email-with-caret trigger button.
  • <SettingsModal> deleted (no other mount sites).
  • Long emails truncate with title= tooltip.

Diff summary

File Change
frontend/packages/settings/src/SettingsModal.tsx deleted (rolled into AccountMenu)
frontend/packages/settings/src/AccountMenu.tsx new — panel body
frontend/packages/settings/src/index.ts exports AccountMenu instead of SettingsModal
frontend/packages/settings/README.md updated to reflect the panel-body model
frontend/packages/sidebar/src/Sidebar.tsx identity area refactored to email-with-caret + Popover
frontend/packages/sidebar/package.json @dar/ui added as workspace dep
frontend/apps/web/src/pages/ListPage.tsx Actions menu uses Popover with min-w-56 max-w-md + truncate items
frontend/pnpm-lock.yaml mechanically updated for the new workspace edge
pyproject.toml version bump 1.0.2 → 1.0.3

Test plan

  • Backend: poetry run pytest -q45 passed, 88% coverage.
  • Frontend: pnpm -w test145 tests passed, 22 files (FilterBar's 11 tests still green).
  • Frontend: pnpm -r typecheck → clean across all 11 packages.
  • Frontend: pnpm -w build → clean. JS bundle 262.07 → 262.12 kB (+50 B), CSS 28.16 → 28.23 kB (+70 B). Net neutral — deleted SettingsModal offsets new AccountMenu.

Publish plan

Same as 1.0.1/1.0.2 — manual set -a; . ./.env; set +a && poetry publish using POETRY_PYPI_TOKEN_PYPI from .env. Tag v1.0.3 + GitHub Release after. The release.yml idempotency guard (PR #569) will detect the version is already on PyPI and short-circuit the upload, so the pypi Deployment lights up green automatically.

Closes

🤖 Generated with Claude Code

…efactor

Three SPA bugs / refactors against v1.0.2, addressed in one PR because
they all converge on the shared Popover primitive in @dar/ui.

#574 + #575 — list-page Actions dropdown (width + outside-click)
-----------------------------------------------------------------
The Actions dropdown opened at a fixed narrow width (~200px) regardless
of label length — long admin.action descriptions wrapped to 3+ lines.
Clicking outside the menu did NOT close it; only clicking the trigger
or selecting an item did.

Fix: replace the hand-rolled inline menu with the shared Popover
primitive, which already handles outside-click + Escape (and is
verified by ListPage's filter dropdowns and DetailPage's
CustomViewsMenu). Apply min-w-56 max-w-md to the panel and
truncate whitespace-nowrap to the items — labels track their content
length up to a sane bound, longer-than-bound labels truncate with the
full text reachable via the existing title= tooltip.

#578 — sidebar identity area (email dropdown over modal)
--------------------------------------------------------
The sidebar identity area was three stacked elements:
1. email + role text on its own row,
2. a standalone Settings button,
3. a Settings modal containing the theme toggle + Sign out.

A modal-around-two-controls is heavier than warranted, and the
inline role label (· superuser) was noise for day-to-day users.

Fix: replace all three with a single email-with-caret button that
opens a dropdown via the shared Popover. The dropdown holds the same
theme toggle + Sign out, plus an optional Signed in as ... · role
caption inside the panel for users who want the info. SettingsModal
deleted (no other mount sites); new AccountMenu component in
@dar/settings is the panel body, consumed inside the Popover by
@dar/sidebar. Long emails truncate with title= tooltip.

Side effects:
- @dar/sidebar gains a workspace dep on @dar/ui (Popover) — already
  used transitively everywhere else.
- @dar/settings exports AccountMenu instead of SettingsModal.
- Bundle changes: 262.07 → 262.12 kB JS (+50 bytes), 28.16 → 28.23 kB
  CSS (+70 bytes). Net neutral despite gaining one more dropdown
  surface — the deleted SettingsModal + Settings cog import roughly
  offset the new AccountMenu.

Closes #574, Closes #575, Closes #578.

Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
@MartinCastroAlvarez MartinCastroAlvarez merged commit 1c53053 into main May 28, 2026
5 checks passed
@MartinCastroAlvarez MartinCastroAlvarez deleted the chore/release-v1.0.3 branch May 28, 2026 18:14
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment